package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.EvStatisticsMapper;
import com.ruoyi.system.domain.EvStatistics;
import com.ruoyi.system.service.IEvStatisticsService;

/**
 * 统计与报Service业务层处理
 * 
 * @author wtd1
 * @date 2025-11-15
 */
@Service
public class EvStatisticsServiceImpl implements IEvStatisticsService 
{
    @Autowired
    private EvStatisticsMapper evStatisticsMapper;

    /**
     * 查询统计与报
     * 
     * @param statId 统计与报主键
     * @return 统计与报
     */
    @Override
    public EvStatistics selectEvStatisticsByStatId(Long statId)
    {
        return evStatisticsMapper.selectEvStatisticsByStatId(statId);
    }

    /**
     * 查询统计与报列表
     * 
     * @param evStatistics 统计与报
     * @return 统计与报
     */
    @Override
    public List<EvStatistics> selectEvStatisticsList(EvStatistics evStatistics)
    {
        return evStatisticsMapper.selectEvStatisticsList(evStatistics);
    }

    /**
     * 新增统计与报
     * 
     * @param evStatistics 统计与报
     * @return 结果
     */
    @Override
    public int insertEvStatistics(EvStatistics evStatistics)
    {
        evStatistics.setCreateTime(DateUtils.getNowDate());
        return evStatisticsMapper.insertEvStatistics(evStatistics);
    }

    /**
     * 修改统计与报
     * 
     * @param evStatistics 统计与报
     * @return 结果
     */
    @Override
    public int updateEvStatistics(EvStatistics evStatistics)
    {
        return evStatisticsMapper.updateEvStatistics(evStatistics);
    }

    /**
     * 批量删除统计与报
     * 
     * @param statIds 需要删除的统计与报主键
     * @return 结果
     */
    @Override
    public int deleteEvStatisticsByStatIds(Long[] statIds)
    {
        return evStatisticsMapper.deleteEvStatisticsByStatIds(statIds);
    }

    /**
     * 删除统计与报信息
     * 
     * @param statId 统计与报主键
     * @return 结果
     */
    @Override
    public int deleteEvStatisticsByStatId(Long statId)
    {
        return evStatisticsMapper.deleteEvStatisticsByStatId(statId);
    }
}
